var app= new Vue({
	el:"#app",
	
	data:{
		subnav:[0,0,0,0,0,0,0,0,0,0],
		button:0,
		img:[
			"./img/img1.jpg",
			"./img/img2.png",
			"./img/img3.jpg",
		],
		index:0
	},
	methods:{
		doit(){
			alert("456");
		},
		change_subnav(i){
			// this.subnav[i]=!this.subnav[i];
			// console.log(i+":"+this.subnav[i]);
			// alert(this.subnav[i]);
			// this.a=0;
			// Vue.set(this.subnav,i,!this.subnav[i])
			for (let t = 0; t <10 ; t++) {
				Vue.set(this.subnav,t,0);
			}
			Vue.set(this.subnav,i,1);
		},
		change(i){
			Vue.set(this.subnav,i,0);
		},
		pic_up(){
			if(this.index!=0){
				this.index--;
			}else{
				this.index=2;
			}
			console.log(this.index);
		},
		pic_next(){
			if(this.index!=2){
				this.index++;
			}else{
				this.index=0;
			}
		}
		
	}
})